Analogous to internal, private variables within a function, allowing for easy re-use.

You can define any many locals block as you need.

locals vs resource

When possible, get a resource’s attribute instead of defining a locals block. The latter risks going out-of-date.